package co.com.javeriana.aes.patrones.universalbank.util;

import java.sql.ResultSet;
import java.sql.Statement;
import java.util.ArrayList;
import java.util.List;

public class DAOManager {

    
    public static void main(String args []) throws Exception {
        
                Statement st = null;
                ResultSet rs = null;
        
        
        
        try {
         
                ConnectDB s = ConnectDB.getInstance();
              
                 st = s.getConnection().createStatement();
                 rs = st.executeQuery("select * from client where user_id="+'"'+ 1136879159 +'"' );

                List<String> list = new ArrayList<String>();
                
                while (rs.next()) {
                    
                    list.add(rs.getString(1));
                    list.add(rs.getString(2));
                    list.add(rs.getString(3));
                    list.add(rs.getString(4));
                    list.add(rs.getString(5));
                    list.add(rs.getString(6));
                    list.add(rs.getString(7));
                    
                }
                
                for (String string : list) {
                    System.out.println(string);
                }

        
          
            
        } catch (Exception e) {
            throw e;
        } finally{
                
            st.close();
            rs.close();
        
        }
    }
}